package com.mashibing.dp.abstractfactory;

// 魔法世界
public class MagicFactory extends AbastractFactory {
    // 返回类型：抽象类，返回对象：实现类的对象
    @Override
    Food createFood() {
        return new MushRoom();
    }

    @Override
    Vehicle createVehicle() {
        return new Broom();
    }

    @Override
    Weapon createWeapon() {
        return new MagicStick();
    }
}
